{#include header/}

<h2>Owner</h2>

<form class="form-horizontal" id="add-owner-form" method="post" action="{#if owner.id is null}addOwner{#else}editOwner?ownerId={owner.id}{/if}" enctype="multipart/form-data">
<div class="form-group has-feedback">
    <div class="form-group">
        <label class="col-sm-2 control-label">First Name</label>
        <div class="col-sm-10">
            <div>
                <input class="form-control" type="text" id="firstName" name="firstName" value="{owner.firstName ?: ''}" />
            </div>
          <span class="glyphicon glyphicon-ok form-control-feedback" aria-hidden="true"></span>
        </div>
    </div>

    <div class="form-group">
        <label class="col-sm-2 control-label">Last Name</label>
        <div class="col-sm-10">
            <div>
                <input class="form-control" type="text" id="lastName" name="lastName" value="{owner.lastName ?: ''}" />
            </div>
          <span class="glyphicon glyphicon-ok form-control-feedback" aria-hidden="true"></span>
          
        </div>
    </div>
    
    <div class="form-group">
        <label class="col-sm-2 control-label">Address</label>
        <div class="col-sm-10">
            <div>
                <input class="form-control" type="text" id="address" name="address" value="{owner.address ?: ''}" />
            </div>
          <span class="glyphicon glyphicon-ok form-control-feedback" aria-hidden="true"></span>
          
        </div>
    </div>
      
    <div class="form-group">
        <label class="col-sm-2 control-label">City</label>
        <div class="col-sm-10">
            <div>
                <input class="form-control" type="text" id="city" name="city" value="{owner.city ?: ''}" />
            </div>
          <span class="glyphicon glyphicon-ok form-control-feedback" aria-hidden="true"></span>
        </div>
    </div>
      
    <div class="form-group">
        <label class="col-sm-2 control-label">Telephone</label>
        <div class="col-sm-10">
            <div>
                <input class="form-control" type="text" id="telephone" name="telephone" value="{owner.telephone ?: ''}" />
            </div>
          <span class="glyphicon glyphicon-ok form-control-feedback" aria-hidden="true"></span>
        </div>
    </div>

</div>
<div class="form-group">
    <div class="col-sm-offset-2 col-sm-10">
        <button class="btn btn-default" type="submit">{#if owner == 'new'}Add{#else}Update{/if} Owner</button>
    </div>
</div>
</form>

{#include footer/}